<?php
	$v_params = $this->getParams();
	$lSolic = $v_params[0];
	$lCli = $v_params[1];
?>
<form name="formOS" id="formOS" method="post" action="./OS/inserirOS">
    <table class="formLayout lista">
        <tr>
            <td><label for="no_os">Nome da OS<span class="required-icon">*</span>:</label></td>
            <td><input name="no_os" type="text" required id="no_os" /></td>
        </tr>
        <tr>
            <td><label for="nu_contrato_os">N&ordm; do Contrato<span class="required-icon">*</span>:</label></td>
            <td><input name="nu_contrato_os" type="text" required id="nu_contrato_os" /></td>
        </tr>
        <tr>
            <td><label for="abertura_os">Data de referência<span class="required-icon">*</span>:</label></td>
            <td><input name="abertura_os" type="text" required id="abertura_os" /></td>
        </tr>
        <tr>
            <td><label for="dt_inicio">Data de início<span class="required-icon">*</span>:</label></td>
            <td><input name="dt_inicio" type="date" required id="dt_inicio" /></td>
        </tr>
        <tr>
            <td>
            	<label for="nu_horas_planejadas">Horas planejadas<span class="required-icon">*</span>:</label>
            </td>
            <td>
            	<input type="number" name="nu_horas_planejadas" id="nu_horas_planejadas" value="0" required />
           	</td>
        </tr>
        <tr>
            <td><label for="nu_horas_executadas">Horas executadas:</label></td>
            <td><input type="number" name="nu_horas_executadas" id="nu_horas_executadas" value="0" /></td>
        </tr>
        <tr>
            <td><label for="vl_os">Valor (R$):</label></td>
            <td><input type="number" step="any" name="vl_os" id="vl_os" value="0.00" /></td>
        </tr>
        <tr>
            <td><label for="dt_termino">Data de término:</label></td>
            <td><input type="date" name="dt_termino" id="dt_termino" /></td>
        </tr>
        <tr>
            <td><label for="fl_aditivo">Aditivo<span class="required-icon">*</span>:</label></td>
            <td>
        		<select style="width:195px;" name="fl_aditivo" id="fl_aditivo">
           			<option value="0">Não</option>
          			<option value="1">Sim</option>
           		</select>
            </td>
        </tr>
        <tr>
            <td><label for="no_solicitante">Solicitante<span class="required-icon">*</span>:</label></td>
            <td>
            	<select style="width:195px;" name="id_solicitante" required id="id_solicitante">
            	  <option value="">Selecione...</option>
                  <?php foreach($lSolic as $slct){ ?> 
                  <option value="<?php echo $slct["id_solicitante"] ?>"><?php echo $slct["no_solicitante"] ?></option>
                  <?php } ?>
                </select>
          </td>
      </tr>
        <tr>
            <td><label for="id_cliente">Cliente<span class="required-icon">*</span>:</label></td>
            <td>
            	<select style="width:195px;" name="id_cliente" required id="id_cliente">
            	  <option value="">Selecione...</option>
                  <?php foreach($lCli as $clt){ ?> 
                  <option value="<?php echo $clt["id_cliente"] ?>"><?php echo $clt["no_cliente"]; ?>
                  </option>
                  <?php } ?>
                </select>
            </td>
        </tr>
        <tr>
            <td colspan="2">Os campos marcados com <span class="required-icon">*</span> 
            são de preenchimento obrigatório</td>
        </tr>
        <tr>
            <td colspan="2"><input type="submit" name="enviar" value="Inserir OS" /></td>
        </tr>
    </table>
</form>